#!/bin/bash
#Filename: autostart.sh

# set the PATH
PATH=$PATH:~/bin/

#conky
which conky > /dev/null 2>&1 && conky -c ~/.conky/conkyrc.nonet > /dev/null 2>&1 &

#tint2
which tint2 > /dev/null 2>&1 && tint2 &

#scim
#if which scim > /dev/null 2>&1; then
#    XMODIFIERS="@im=SCIM"
#    export XMODIFIERS
#    GTK_IM_MODULE="xim"
#    export GTK_IM_MODULE
#    scim -d > /dev/null 2>&1 &
#fi

#file manager
which thunar > /dev/null 2>&1 && thunar --daemon &

#nm-applet
which nm-applet > /dev/null 2>&1 && nm-applet &

#mldonky
if which mlnet > /dev/null 2>&1; then
    if ps -e | grep mlnet > /dev/null 2>&1; then
        :
    else
        mlnet > /dev/null 2>&1 & 
    fi
fi

#set the background
if which feh > /dev/null 2>&1; then
    feh --bg-scale ~/.background/back.jpg &
else
    xsetroot -solid black &
fi
